const app = getApp();
Component({
    data: {
        current:0,

    },
    properties: {
        videoList: {
            type: Array
        }
    },
    methods: {
        toVideoPlay(e){
            const { item } = e.currentTarget.dataset;
            let url = ""
            if(item.video_type === "videoPlayer"){
                url = `/page/shortDramaMarket/video-player/index?tt_album_id=${item.ablum_id}&tt_episode_id=${item.episodes[0].episodes_id}`
            }else if(item.video_type === "playletPlugin"){
                url = `/page/shortDramaMarket/playlet-plugin/index?tt_album_id=${item.ablum_id}&tt_episode_id=${item.episodes[0].episodes_id}`
            }
            tt.navigateTo({
                url: url,
                success: (res) => {

                },
                fail: (res) => {
                    console.log(res);
                },
            });
        },
        switchTap(e){
            const {current} = e.detail;
            this.setData({
                current,
            })
        }
    }
})